package com.sanfeng.smbms;


import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.core.env.Environment;

@SpringBootApplication
public class SmbmsApplication {
    public static void main(String[] args) {
        //SpringApplication.run(SmbmsApplication.class, args);
        ConfigurableApplicationContext context = SpringApplication.run(SmbmsApplication.class, args);
        Environment environment = context.getBean(Environment.class);
        System.out.println("访问链接：http://localhost:" + environment.getProperty("server.port")
                + environment.getProperty("server.servlet.context-path"));
    }

}
